package net.tbao.product.feign.fallback;

import net.tbao.common.exception.BizCodeEnume;
import net.tbao.common.to.SkuReductionTo;
import net.tbao.common.to.SpuBoundTo;
import net.tbao.common.to.es.SkuEsModel;
import net.tbao.common.utils.R;
import net.tbao.product.feign.*;
import net.tbao.product.vo.PersonalVo;
import org.springframework.stereotype.Component;

import java.util.List;

@Component
public class ProtectFeignServiceFallBack implements SeckillFeigService, CouponFeignService, PersonalFeignService, SearchFeignService, WareFeignService {
    @Override
    public R skuSeckillInfo(Long skuId) {
        return R.error(BizCodeEnume.TO_MANY_REQUEST.getCode(),BizCodeEnume.TO_MANY_REQUEST.getMsg());
    }

    @Override
    public R saveSpuBounds(SpuBoundTo spuBoundTo) {
        return R.error(BizCodeEnume.TO_MANY_REQUEST.getCode(),BizCodeEnume.TO_MANY_REQUEST.getMsg());
    }

    @Override
    public R saveSkuReduction(SkuReductionTo skuReductionTo) {
        return R.error(BizCodeEnume.TO_MANY_REQUEST.getCode(),BizCodeEnume.TO_MANY_REQUEST.getMsg());
    }

    @Override
    public R queryByPersonal(PersonalVo vo) {
        return R.error(BizCodeEnume.TO_MANY_REQUEST.getCode(),BizCodeEnume.TO_MANY_REQUEST.getMsg());
    }

    @Override
    public R productStstusUp(List<SkuEsModel> esModels) {
        return R.error(BizCodeEnume.TO_MANY_REQUEST.getCode(),BizCodeEnume.TO_MANY_REQUEST.getMsg());
    }

    @Override
    public R getSkusHasStock(List<Long> skuIds) {
        return R.error(BizCodeEnume.TO_MANY_REQUEST.getCode(),BizCodeEnume.TO_MANY_REQUEST.getMsg());
    }
}
